﻿using System;
using UnityEngine;

namespace Studio
{
	// Token: 0x0200050F RID: 1295
	public class ExitScene : MonoBehaviour
	{
		// Token: 0x06002108 RID: 8456 RVA: 0x000CB518 File Offset: 0x000C9718
		private void Awake()
		{
			this.timeScale = Time.timeScale;
			Time.timeScale = 0f;
		}

		// Token: 0x06002109 RID: 8457 RVA: 0x000CB530 File Offset: 0x000C9730
		private void Start()
		{
			this.yes.addOnClick = delegate()
			{
				Singleton<Scene>.Instance.GameEnd(false);
				Singleton<Scene>.Instance.isSkipGameExit = false;
			};
			this.no.addOnClick = delegate()
			{
				Singleton<Scene>.Instance.UnLoad();
				Singleton<Scene>.Instance.isGameEndCheck = true;
				Singleton<Scene>.Instance.isSkipGameExit = false;
			};
		}

		// Token: 0x0600210A RID: 8458 RVA: 0x000CB590 File Offset: 0x000C9790
		private void OnDestroy()
		{
			Time.timeScale = this.timeScale;
		}

		// Token: 0x04002294 RID: 8852
		[SerializeField]
		private VoiceNode yes;

		// Token: 0x04002295 RID: 8853
		[SerializeField]
		private VoiceNode no;

		// Token: 0x04002296 RID: 8854
		private float timeScale = 1f;
	}
}
